<%@ include file="/include/taglibs.jsp"%>
<%@ page contentType="text/html; charset=UTF-8"%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>订单管理</title>
<link href="${ctx}/css/orderForm.css" rel="stylesheet" type="text/css" />
</head>
<body>
<%@include file="/include/head.jsp"%>
	 <!--页面中部内容-开始-->
	 <div class="common_wraper">
	 	<div class="winTopOuter">
	 		<div class="winTopInner"></div>
	 	</div>
	 	<div class="winContent">
	 		<div class="winTitle">
	 			请填写用户注册信息
	 		</div>
	 		<div class='statusImg_buyCar'></div><%--状态图片 --%>
	 		<div>我是购物车</div>
	 	</div>
	 	<div class="winBottomOuter">
	 		<div class="winBottomInner"></div>
	 	</div>
	 </div>
	 <!--页面中部内容-结束-->
	<%@include file="/include/footer.jsp" %>
</body>
<script type="text/javascript">
	JBF.addEvent(JBF.el("add"),"click",function(){
		var value=JBF.el("buycount").value;
		if(!value){
			JBF.el("buycount").value=1;
		}else{
			JBF.el("buycount").value=Number(value)+1;
		}
	});
	JBF.addEvent(JBF.el("minus"),"click",function(){
		var value=JBF.el("buycount").value;
		if(value<=1){
			JBF.el("buycount").value=1;
		}else{
			JBF.el("buycount").value=Number(value)-1;
		}
	});
	function flushOrderForm(){
		var urlValue=JBF.el("url").value;
		if(urlValue&&urlValue.length>0){
			var urlStr=basePath+"commodity_extend!snatchAtByUrl.do?url="+encodeURIComponent(urlValue);
			JBF.ajax(urlStr,"",function(msg){
				if(msg.ajaxStatus){
					switch (msg.ajaxStatus){
						case 'ok':
							var pojo=msg.pojoMap;
							JBF.el("commodityname").value=pojo["commodityname"];
							JBF.el("shopName").value=pojo["shopName"];
							JBF.el("price").value=pojo["price"];
							JBF.el("freight").value=pojo["freight"]?pojo["freight"]:"0.00";
							JBF.el("commodityImg").innerHTML="<img width=200px height=200px src='"+pojo["imgurl"]+"'>";
							break;
						case 'fail':
							break;
						case 'urlNull':
							break;
						case 'error':
							break;
					}
				}
			});
		}
	}
	(function(){
		setTimeout("flushOrderForm()",100);
		JBF.addEvent(JBF.el("submitText"),"click",function(){
			alert(2222);
		});
		JBF.addEvent(JBF.el("clearText"),"click",function(){
			JBF.el("url").value="";
			JBF.el("commodityname").value="";
			JBF.el("shopName").value="";
			JBF.el("price").value="0.00";
			JBF.el("freight").value="0.00";
			JBF.el("commodityImg").innerHTML="<img width=200px height=200px src='a'>";
		});
	})();
</script>
</html>